From: Florian Müllner Date: Sun, 12 Mar 2023 21:55:45 +0000 (+0100) Subject: status/volume: Ignore capitalization for headphone detection X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~371^2^2~2 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=b8dcf85cc85063baf9eaf5d3a319da1a262c9a85;p=gnome-shell.git status/volume: Ignore capitalization for headphone detection When we can't detect a headphone by form factor, we do a string match on the port name. A match on 'Headphone' isn't less likely to be valid than a match on 'headphone', so make sure we ignore capitalization. Part-of: --- diff --git a/js/ui/status/volume.js b/js/ui/status/volume.js index fd6c8e7d6..91706343a 100644 --- a/js/ui/status/volume.js +++ b/js/ui/status/volume.js @@ -319,7 +319,7 @@ class OutputStreamSlider extends StreamSlider { // of different identifiers for headphones, and I could // not find the complete list if (sink.get_ports().length > 0) - return sink.get_port().port.includes('headphone'); + return sink.get_port().port.toLowerCase().includes('headphone'); return false; }